using System;
using System.ComponentModel;
using System.Xml.Serialization;

namespace com.exceptionalsoftware.spacetime.KML
{
	[Serializable()]
    [XmlType(TypeName = "ModelType")]
    public class Model : Geometry
	{
        private AltitudeModeEnum altitudeModeField;
        private Orientation orientationField;
        private Location locationField;
        private Scale scaleField;
        private Link linkField;
        private ResourceMap resourceMapField;

        public Model()
        {
            this.altitudeModeField = AltitudeModeEnum.ClampToGround;
        }

        [XmlElement(ElementName = "altitudeMode", Type = typeof(AltitudeModeEnum))]
        [DefaultValue(AltitudeModeEnum.ClampToGround)]
        public AltitudeModeEnum AltitudeMode
        {
            get { return this.altitudeModeField; }
            set { this.altitudeModeField = value; }
        }

        [XmlElement(ElementName = "Orientation", Type = typeof(Orientation))]
        public Orientation Orientation
        {
            get { return this.orientationField; }
            set { this.orientationField = value; }
        }

        [XmlElement(ElementName = "Location", Type = typeof(Location))]
        public Location Location
        {
            get { return this.locationField; }
            set { this.locationField = value; }
        }

        [XmlElement(ElementName = "Scale", Type = typeof(Scale))]
        public Scale Scale
        {
            get { return this.scaleField; }
            set { this.scaleField = value; }
        }

        [XmlElement(ElementName = "Link", Type = typeof(Link))]
        public Link Link
        {
            get { return this.linkField; }
            set { this.linkField = value; }
        }

        [XmlElement(ElementName = "ResourceMap", Type = typeof(ResourceMap))]
        public ResourceMap ResourceMap
        {
            get { return this.resourceMapField; }
            set { this.resourceMapField = value; }
        }
    }
}